﻿{#template MAIN}
<table id="gridProvider" cellpadding="5" cellspacing="0" class="grid">
    <thead>
        <th>Seq</th>
        <th>Provider #</th>
        <th>Provider Name</th>
        <th>Address Line 1</th>
        <th><a class="btnNew" href="/Pages/Operators/ProviderItem.aspx">Add</a></th>
    </thead>
    <tbody>
    {#foreach $T.List as provider}
        <tr class="{#cycle values=['','evenRow']}">
            <td align="center">{$T.provider$index + 1}</td>
            {#include ROW root=$T.provider}
            <td>
                <a href="/Pages/Operators/ProviderItem.aspx?ProviderID={$T.provider.ProviderID}" class="btnEdit">Edit</a>
                {#if $T.IsAdmin }
                |&nbsp;<a providerid="{$T.provider.ProviderID}" class="btnDelete">Delete</a>
                {#/if}
            </td>
        </tr>
    {#/for}
    </tbody>
    <!--tfoot>
        <th colspan="10" >
        Page 
        {#for index = 1 to Math.ceil($T.TotalRecords/$T.PageSize)}
            <input type="button" class={#if $T.index == $T.PageNumber + 1 }"actived pagenumber" {#else}"pagenumber" {#/if} value="{$T.index}" />
        {#/for}
        of {$T.TotalRecords} total records
        </th>
    </tfoot-->
</table>
{#/template MAIN}

{#template ROW}     
<td>{$T.ProviderNumber}</td>
<td>{$T.ProviderName}</td>
<td>{$T.AddressLine1}</td>
{#/template ROW}